package com.zl.learning.gc;

public class TestGC {

    /**
     [GC (System.gc()) [PSYoungGen: 3277K->840K(37888K)] 68814K->66384K(123904K), 0.0008455 secs] [Times: user=0.00 sys=0.00, real=0.00 secs]
     [Full GC (System.gc()) [PSYoungGen: 840K->0K(37888K)] [ParOldGen: 65544K->66182K(86016K)] 66384K->66182K(123904K), [Metaspace: 3212K->3212K(1056768K)], 0.0042879 secs] [Times: user=0.02 sys=0.00, real=0.00 secs]
     Heap
     PSYoungGen      total 37888K, used 328K [0x00000000d6500000, 0x00000000d8f00000, 0x0000000100000000)
     eden space 32768K, 1% used [0x00000000d6500000,0x00000000d6552030,0x00000000d8500000)
     from space 5120K, 0% used [0x00000000d8500000,0x00000000d8500000,0x00000000d8a00000)
     to   space 5120K, 0% used [0x00000000d8a00000,0x00000000d8a00000,0x00000000d8f00000)
     ParOldGen       total 86016K, used 66182K [0x0000000082e00000, 0x0000000088200000, 0x00000000d6500000)
     object space 86016K, 76% used [0x0000000082e00000,0x0000000086ea18a8,0x0000000088200000)
     Metaspace       used 3218K, capacity 4496K, committed 4864K, reserved 1056768K
     class space    used 350K, capacity 388K, committed 512K, reserved 1048576K
     */
    /**
     [GC (System.gc()) [PSYoungGen: 3277K->808K(37888K)] 68814K->66352K(123904K), 0.0009748 secs] [Times: user=0.00 sys=0.00, real=0.00 secs]
     [Full GC (System.gc()) [PSYoungGen: 808K->0K(37888K)] [ParOldGen: 65544K->646K(86016K)] 66352K->646K(123904K), [Metaspace: 3212K->3212K(1056768K)], 0.0045877 secs] [Times: user=0.08 sys=0.00, real=0.00 secs]
     Heap
     PSYoungGen      total 37888K, used 328K [0x00000000d6500000, 0x00000000d8f00000, 0x0000000100000000)
     eden space 32768K, 1% used [0x00000000d6500000,0x00000000d6552030,0x00000000d8500000)
     from space 5120K, 0% used [0x00000000d8500000,0x00000000d8500000,0x00000000d8a00000)
     to   space 5120K, 0% used [0x00000000d8a00000,0x00000000d8a00000,0x00000000d8f00000)
     ParOldGen       total 86016K, used 646K [0x0000000082e00000, 0x0000000088200000, 0x00000000d6500000)
     object space 86016K, 0% used [0x0000000082e00000,0x0000000082ea1898,0x0000000088200000)
     Metaspace       used 3218K, capacity 4496K, committed 4864K, reserved 1056768K
     class space    used 350K, capacity 388K, committed 512K, reserved 1048576K
     */

    public static void main(String[] args) {
        {
            byte[] placeholder = new byte[64 * 1024 * 1024];
        }
        System.out.println("HelloWorld");
//        int a = 0;
        System.gc();
    }
}
